<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GtkPreview</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
<link rel="home" href="index.html" title="GTK+ 2 Reference Manual">
<link rel="up" href="DeprecatedObjects.html" title="Deprecated">
<link rel="prev" href="GtkPixmap.html" title="GtkPixmap">
<link rel="next" href="GtkProgress.html" title="GtkProgress">
<meta name="generator" content="GTK-Doc V1.18 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="GtkPixmap.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="DeprecatedObjects.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">GTK+ 2 Reference Manual</th>
<td><a accesskey="n" href="GtkProgress.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#GtkPreview.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#GtkPreview.description" class="shortcut">Description</a>
                   | 
                  <a href="#GtkPreview.object-hierarchy" class="shortcut">Object Hierarchy</a>
                   | 
                  <a href="#GtkPreview.implemented-interfaces" class="shortcut">Implemented Interfaces</a>
                   | 
                  <a href="#GtkPreview.properties" class="shortcut">Properties</a>
</td></tr>
</table>
<div class="refentry">
<a name="GtkPreview"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="GtkPreview.top_of_page"></a>GtkPreview</span></h2>
<p>GtkPreview — A widget to display RGB or grayscale data</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv">
<a name="GtkPreview.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">
#include &lt;gtk/gtk.h&gt;

struct              <a class="link" href="GtkPreview.html#GtkPreview-struct" title="struct GtkPreview">GtkPreview</a>;
struct              <a class="link" href="GtkPreview.html#GtkPreviewInfo" title="struct GtkPreviewInfo">GtkPreviewInfo</a>;
union               <a class="link" href="GtkPreview.html#GtkDitherInfo" title="union GtkDitherInfo">GtkDitherInfo</a>;
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-uninit" title="gtk_preview_uninit ()">gtk_preview_uninit</a>                  (<em class="parameter"><code><span class="type">void</span></code></em>);
<a class="link" href="GtkWidget.html" title="GtkWidget"><span class="returnvalue">GtkWidget</span></a> *         <a class="link" href="GtkPreview.html#gtk-preview-new" title="gtk_preview_new ()">gtk_preview_new</a>                     (<em class="parameter"><code><a class="link" href="gtk-Standard-Enumerations.html#GtkPreviewType" title="enum GtkPreviewType"><span class="type">GtkPreviewType</span></a> type</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-size" title="gtk_preview_size ()">gtk_preview_size</a>                    (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-put" title="gtk_preview_put ()">gtk_preview_put</a>                     (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="../gdk/gdk-Windows.html#GdkWindow"><span class="type">GdkWindow</span></a> *window</code></em>,
                                                         <em class="parameter"><code><a href="../gdk/gdk-Graphics-Contexts.html#GdkGC"><span class="type">GdkGC</span></a> *gc</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> srcx</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> srcy</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> destx</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> desty</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-draw-row" title="gtk_preview_draw_row ()">gtk_preview_draw_row</a>                (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> w</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-expand" title="gtk_preview_set_expand ()">gtk_preview_set_expand</a>              (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> expand</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-gamma" title="gtk_preview_set_gamma ()">gtk_preview_set_gamma</a>               (<em class="parameter"><code><span class="type">double</span> gamma_</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-color-cube" title="gtk_preview_set_color_cube ()">gtk_preview_set_color_cube</a>          (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> nred_shades</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> ngreen_shades</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> nblue_shades</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> ngray_shades</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-install-cmap" title="gtk_preview_set_install_cmap ()">gtk_preview_set_install_cmap</a>        (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> install_cmap</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-reserved" title="gtk_preview_set_reserved ()">gtk_preview_set_reserved</a>            (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> nreserved</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-set-dither" title="gtk_preview_set_dither ()">gtk_preview_set_dither</a>              (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="../gdk/gdk-GdkRGB.html#GdkRgbDither"><span class="type">GdkRgbDither</span></a> dither</code></em>);
<a href="../gdk/gdk-Visuals.html#GdkVisual"><span class="returnvalue">GdkVisual</span></a> *         <a class="link" href="GtkPreview.html#gtk-preview-get-visual" title="gtk_preview_get_visual ()">gtk_preview_get_visual</a>              (<em class="parameter"><code><span class="type">void</span></code></em>);
<a href="../gdk/gdk-Colormaps-and-Colors.html#GdkColormap"><span class="returnvalue">GdkColormap</span></a> *       <a class="link" href="GtkPreview.html#gtk-preview-get-cmap" title="gtk_preview_get_cmap ()">gtk_preview_get_cmap</a>                (<em class="parameter"><code><span class="type">void</span></code></em>);
<a class="link" href="GtkPreview.html#GtkPreviewInfo" title="struct GtkPreviewInfo"><span class="returnvalue">GtkPreviewInfo</span></a> *    <a class="link" href="GtkPreview.html#gtk-preview-get-info" title="gtk_preview_get_info ()">gtk_preview_get_info</a>                (<em class="parameter"><code><span class="type">void</span></code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GtkPreview.html#gtk-preview-reset" title="gtk_preview_reset ()">gtk_preview_reset</a>                   (<em class="parameter"><code><span class="type">void</span></code></em>);
</pre>
</div>
<div class="refsect1">
<a name="GtkPreview.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
  <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
   +----<a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GInitiallyUnowned">GInitiallyUnowned</a>
         +----<a class="link" href="GtkObject.html" title="GtkObject">GtkObject</a>
               +----<a class="link" href="GtkWidget.html" title="GtkWidget">GtkWidget</a>
                     +----GtkPreview
</pre>
</div>
<div class="refsect1">
<a name="GtkPreview.implemented-interfaces"></a><h2>Implemented Interfaces</h2>
<p>
GtkPreview implements
 AtkImplementorIface and  <a class="link" href="GtkBuildable.html" title="GtkBuildable">GtkBuildable</a>.</p>
</div>
<div class="refsect1">
<a name="GtkPreview.properties"></a><h2>Properties</h2>
<pre class="synopsis">
  "<a class="link" href="GtkPreview.html#GtkPreview--expand" title='The "expand" property'>expand</a>"                   <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
</pre>
</div>
<div class="refsect1">
<a name="GtkPreview.description"></a><h2>Description</h2>
<p>
The <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> widget provides a simple interface
used to display images as RGB or grayscale data.
It's deprecated; just use a <a href="http://library.gnome.org/devel/gdk-pixbuf/unstable/gdk-pixbuf-The-GdkPixbuf-Structure.html#GdkPixbuf"><span class="type">GdkPixbuf</span></a> displayed by a <a class="link" href="GtkImage.html" title="GtkImage"><span class="type">GtkImage</span></a>, or
perhaps a <a class="link" href="GtkDrawingArea.html" title="GtkDrawingArea"><span class="type">GtkDrawingArea</span></a>. <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> has no advantage over those
approaches.
</p>
</div>
<div class="refsect1">
<a name="GtkPreview.details"></a><h2>Details</h2>
<div class="refsect2">
<a name="GtkPreview-struct"></a><h3>struct GtkPreview</h3>
<pre class="programlisting">struct GtkPreview;</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">GtkPreview</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
The <a class="link" href="GtkPreview.html#GtkPreview-struct" title="struct GtkPreview"><span class="type">GtkPreview</span></a> struct contains private data only, and
should be accessed using the functions below.
</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkPreviewInfo"></a><h3>struct GtkPreviewInfo</h3>
<pre class="programlisting">struct GtkPreviewInfo {
  guchar *lookup;

  gdouble gamma;
};
</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">GtkPreviewInfo</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Contains information about global properties
of preview widgets.
The <a class="link" href="GtkPreview.html#GtkPreviewInfo" title="struct GtkPreviewInfo"><span class="type">GtkPreviewInfo</span></a> struct contains the following fields.
(These fields should be considered read-only. They should never be set by
an application.)
</p>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td>
<a href="../gdk/gdk-Visuals.html#GdkVisual"><span class="type">GdkVisual</span></a> *visual;</td>
<td>the visual used by all previews.</td>
</tr>
<tr>
<td>
<a href="../gdk/gdk-Colormaps-and-Colors.html#GdkColormap"><span class="type">GdkColormap</span></a> *cmap;</td>
<td>the colormap used by all previews.</td>
</tr>
<tr>
<td>gdouble gamma;</td>
<td>the gamma correction value used by all previews (See <a class="link" href="GtkPreview.html#gtk-preview-set-gamma" title="gtk_preview_set_gamma ()"><code class="function">gtk_preview_set_gamma()</code></a>).</td>
</tr>
</tbody>
</table></div>
<p>
</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkDitherInfo"></a><h3>union GtkDitherInfo</h3>
<pre class="programlisting">union _GtkDitherInfo
{
  gushort s[2];
  guchar c[4];
};
</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">GtkDitherInfo</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This union not used in GTK+.
</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-uninit"></a><h3>gtk_preview_uninit ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_uninit                  (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_uninit</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated and does nothing.
</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-new"></a><h3>gtk_preview_new ()</h3>
<pre class="programlisting"><a class="link" href="GtkWidget.html" title="GtkWidget"><span class="returnvalue">GtkWidget</span></a> *         gtk_preview_new                     (<em class="parameter"><code><a class="link" href="gtk-Standard-Enumerations.html#GtkPreviewType" title="enum GtkPreviewType"><span class="type">GtkPreviewType</span></a> type</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_new</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Create a new preview widget.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td>
<td>the type data contained by the widget.
(Grayscale or RGB)</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>a new <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-size"></a><h3>gtk_preview_size ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_size                    (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_size</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Set the size that the preview widget will request
in response to a "size_request" signal. The
drawing area may actually be allocated a size
larger than this depending on how it is packed
within the enclosing containers. The effect
of this is determined by whether the preview
is set to expand or not (see <code class="function">gtk_preview_expand()</code>)
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>width</code></em> :</span></p></td>
<td>the new width.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>height</code></em> :</span></p></td>
<td>the new height.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-put"></a><h3>gtk_preview_put ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_put                     (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="../gdk/gdk-Windows.html#GdkWindow"><span class="type">GdkWindow</span></a> *window</code></em>,
                                                         <em class="parameter"><code><a href="../gdk/gdk-Graphics-Contexts.html#GdkGC"><span class="type">GdkGC</span></a> *gc</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> srcx</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> srcy</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> destx</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> desty</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_put</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Takes a portion of the contents of a preview widget
and draws it onto the given drawable, <em class="parameter"><code>window</code></em>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>window</code></em> :</span></p></td>
<td>a window or pixmap.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>gc</code></em> :</span></p></td>
<td>The graphics context for the operation. Only the
clip mask for this GC matters.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>srcx</code></em> :</span></p></td>
<td>the x coordinate of the upper left corner in the source image.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>srcy</code></em> :</span></p></td>
<td>the y coordinate of the upper left corner in the source image.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>destx</code></em> :</span></p></td>
<td>the x coordinate of the upper left corner in the destination image.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>desty</code></em> :</span></p></td>
<td>the y coordinate of the upper left corner in the destination image.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>width</code></em> :</span></p></td>
<td>the width of the rectangular portion to draw.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>height</code></em> :</span></p></td>
<td>the height of the rectangular portion to draw.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-draw-row"></a><h3>gtk_preview_draw_row ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_draw_row                (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> w</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_draw_row</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Sets the data for a portion of a row.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td>
<td>the new data for the portion. It should contain
<em class="parameter"><code>w</code></em> bytes of data if the preview is of type
GTK_TYPE_GRAYSCALE, and 3*<em class="parameter"><code>w</code></em> bytes of data
if the preview is of type GTK_TYPE_COLOR.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>x</code></em> :</span></p></td>
<td>the starting value on the row to set.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>y</code></em> :</span></p></td>
<td>the row to change.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>w</code></em> :</span></p></td>
<td>the number of pixels in the row to change.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-set-expand"></a><h3>gtk_preview_set_expand ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_expand              (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> expand</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_expand</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Determines the way that the the preview widget behaves
when the size it is allocated is larger than the requested
size. If <em class="parameter"><code>expand</code></em> is <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a>, then the preview's window
and buffer will be no larger than the size set with
<a class="link" href="GtkPreview.html#gtk-preview-size" title="gtk_preview_size ()"><code class="function">gtk_preview_size()</code></a>, and the data set will be centered
in the allocation if it is larger. If <em class="parameter"><code>expand</code></em> is <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>
then the window and buffer will expand with the allocation;
the application is responsible for catching
the "size_allocate" signal and providing the data
appropriate for this size.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>expand</code></em> :</span></p></td>
<td>whether the preview's window should expand or not.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-set-gamma"></a><h3>gtk_preview_set_gamma ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_gamma               (<em class="parameter"><code><span class="type">double</span> gamma_</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_gamma</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Set the gamma-correction value for all preview widgets.
(This function will eventually be replaced with a
function that sets a per-preview-widget gamma value).
The resulting intensity is given by:
<code class="literal">destination_value * pow (source_value/255, 1/gamma)</code>.
The gamma value is applied when the data is
set with <a class="link" href="GtkPreview.html#gtk-preview-draw-row" title="gtk_preview_draw_row ()"><code class="function">gtk_preview_draw_row()</code></a> so changing this
value will not affect existing data in preview
widgets.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>gamma_</code></em> :</span></p></td>
<td>the new gamma value.</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-set-color-cube"></a><h3>gtk_preview_set_color_cube ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_color_cube          (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> nred_shades</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> ngreen_shades</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> nblue_shades</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> ngray_shades</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_color_cube</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated and does nothing. GdkRGB
automatically picks an optimium color cube for the
display.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>nred_shades</code></em> :</span></p></td>
<td>ignored</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>ngreen_shades</code></em> :</span></p></td>
<td>ignored</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>nblue_shades</code></em> :</span></p></td>
<td>ignored</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>ngray_shades</code></em> :</span></p></td>
<td>ignored</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-set-install-cmap"></a><h3>gtk_preview_set_install_cmap ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_install_cmap        (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> install_cmap</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_install_cmap</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated
and does nothing. GdkRGB will automatically pick
a private colormap if it cannot allocate sufficient
colors.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>install_cmap</code></em> :</span></p></td>
<td>ignored.</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-set-reserved"></a><h3>gtk_preview_set_reserved ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_reserved            (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> nreserved</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_reserved</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated and does nothing.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>nreserved</code></em> :</span></p></td>
<td>ignored.</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-set-dither"></a><h3>gtk_preview_set_dither ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_set_dither              (<em class="parameter"><code><a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a> *preview</code></em>,
                                                         <em class="parameter"><code><a href="../gdk/gdk-GdkRGB.html#GdkRgbDither"><span class="type">GdkRgbDither</span></a> dither</code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_set_dither</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Set the dithering mode for the display.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>preview</code></em> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>dither</code></em> :</span></p></td>
<td>the dithering mode.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-get-visual"></a><h3>gtk_preview_get_visual ()</h3>
<pre class="programlisting"><a href="../gdk/gdk-Visuals.html#GdkVisual"><span class="returnvalue">GdkVisual</span></a> *         gtk_preview_get_visual              (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_get_visual</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Returns the visual used by preview widgets. This
function is deprecated, and you should use
<a href="../gdk/gdk-GdkRGB.html#gdk-rgb-get-visual"><code class="function">gdk_rgb_get_visual()</code></a> instead.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>the visual for previews.</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-get-cmap"></a><h3>gtk_preview_get_cmap ()</h3>
<pre class="programlisting"><a href="../gdk/gdk-Colormaps-and-Colors.html#GdkColormap"><span class="returnvalue">GdkColormap</span></a> *       gtk_preview_get_cmap                (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_get_cmap</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Returns the colormap used by preview widgets. This
function is deprecated, and you should use
<a href="../gdk/gdk-GdkRGB.html#gdk-rgb-get-cmap"><code class="function">gdk_rgb_get_cmap()</code></a> instead.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>the colormap for previews.</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-get-info"></a><h3>gtk_preview_get_info ()</h3>
<pre class="programlisting"><a class="link" href="GtkPreview.html#GtkPreviewInfo" title="struct GtkPreviewInfo"><span class="returnvalue">GtkPreviewInfo</span></a> *    gtk_preview_get_info                (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_get_info</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Return a <a class="link" href="GtkPreview.html#GtkPreviewInfo" title="struct GtkPreviewInfo"><span class="type">GtkPreviewInfo</span></a> structure containing
global information about preview widgets.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>a <a class="link" href="GtkPreview.html#GtkPreviewInfo" title="struct GtkPreviewInfo"><span class="type">GtkPreviewInfo</span></a> structure. The return
value belongs to GTK+ and must not be modified
or freed.</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-preview-reset"></a><h3>gtk_preview_reset ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_preview_reset                   (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gtk_preview_reset</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This function is deprecated and does nothing. It was
once used for changing the colormap and visual on the fly.
</p>
</div>
</div>
<div class="refsect1">
<a name="GtkPreview.property-details"></a><h2>Property Details</h2>
<div class="refsect2">
<a name="GtkPreview--expand"></a><h3>The <code class="literal">"expand"</code> property</h3>
<pre class="programlisting">  "expand"                   <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write</pre>
<p>Whether the preview widget should take up the entire space it is allocated.</p>
<p>Default value: FALSE</p>
</div>
</div>
<div class="refsect1">
<a name="GtkPreview.see-also"></a><h2>See Also</h2>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><span class="type">GdkRGB</span></span></p></td>
<td><p>the backend used by <a class="link" href="GtkPreview.html" title="GtkPreview"><span class="type">GtkPreview</span></a>.</p></td>
</tr></tbody>
</table></div>
<p>
</p>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.18</div>
</body>
</html>